//
//  Data.m
//  Homework_22
//
//  Created by 徐昊 on 16/8/13.
//  Copyright © 2016年 徐昊. All rights reserved.
//

#import "Data.h"

@implementation Data
- (void)setValue:(id)value forKey:(NSString *)key {
    [super setValue:value forKey:key];
    if ([key isEqualToString:@"contents"]) {
        _contents = [Contents modelWithDic:value];
    }
    if ([key isEqualToString:@"mv_show_play"]) {
        NSMutableArray<MV_show_play *> *array = [NSMutableArray array];
        for (NSDictionary *dic in value) {
            MV_show_play *play = [MV_show_play modelWithDic:dic];
            [array addObject:play];
        }
        _mv_show_play = array;
    }
}
@end
